﻿<Application x:Class="Snipps.App"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:Common="clr-namespace:Snipps.Infrastructure"
             xmlns:ViewModels="clr-namespace:Snipps.ViewModels"
             xmlns:Views="clr-namespace:Snipps.Views"
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
             xmlns:Pages="clr-namespace:Snipps.ViewModels.Pages"
             StartupUri="Views\MainWindow.xaml"
             mc:Ignorable="d">

    <Application.Resources>

        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <Common:SharedResourceDictionary Source="pack://application:,,,/Snipps;component/Skins/DarkBlue.xaml" />
                <Common:SharedResourceDictionary Source="pack://application:,,,/Snipps;component/Resources/ResourceLibrary.xaml" />
            </ResourceDictionary.MergedDictionaries>
            <Style TargetType="{x:Type Rectangle}" />
            <!--  Global View Model Locator  -->
            <ViewModels:ViewModelLocator x:Key="Locator"
                                         d:IsDataSource="True" />
            <DataTemplate DataType="{x:Type Pages:FilterViewModel}">
                <Views:FilterView />
            </DataTemplate>

            <DataTemplate DataType="{x:Type Pages:EditSnippetViewModel}">
                <Views:EditSnippetView />
            </DataTemplate>

            <DataTemplate DataType="{x:Type Pages:EditTagViewModel}">
                <Views:EditTagView />
            </DataTemplate>


        </ResourceDictionary>

    </Application.Resources>

</Application>